<div ng-controller="GiftsCtrl" ng-init="addAction()" class="sui-form form-horizontal">
    <form name="itemForm" novalidate ng-submit="saveData()">
        <ul class="sui-breadcrumb">
            <li>
                <a href="#/gifts/list">打卡有礼</a>
            </li>
            <li class="active">
                创建
            </li>
        </ul>
        <div class="control-group">
            <label class="control-label v-top">
                <b style="color: #f00;">*</b> 活动标题：</label>
            <div class="controls">
                <input ng-model="gift.name" name="name" type="text" value="" class="input-xlarge" required>
                <div ng-show="itemForm.name.$error.required" class="sui-msg msg-error msg-clear help-block error">
                    <div class="msg-con">{{'required'| translate}}</div>
                    <s class="msg-icon"></s>
                </div>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label v-top"> 类型：</label>
            <div class="controls">
                <gift-type ng-model="gift.type" dft="1" stype="{{gift.gift_id?1:''}}"></gift-type>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label v-top"> 是否有效:</label>
            <div class="controls">
                <gift-effective ng-model="gift.effective" dft="1"></gift-effective>
            </div>
        </div>
        <div ng-if="gift.type==4">
            <div class="control-group">
                <label class="control-label v-top">配置参数</label>
                <div class="controls">
                    <div>
                        <button class="sui-btn btn-primary" type="button" ng-click="setDesc(4)">添加默认数据</button>
                    </div>
                    <div>
                        <div>猜图题</div>
                        <div ng-if="gift.desc&&gift.desc.bg1">
                            <div>猜图页面背景</div>

                            <img ng-src="{{gift.desc.bg1}}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.bg1" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <!-- <div>
                            <div>结果页面色成功背景色</div>
                            <div style="display: inline-block;">
                                <color-assembly color="gift.desc.bgColor1" isname="bgColor1" name="bgColor1"></color-assembly>
                            </div>
                        </div>
                        <div>
                            <div>结果页面失败背景色</div>
                            <div style="display: inline-block;">
                                <color-assembly color="gift.desc.bgColor2" isname="bgColor2" name="bgColor2"></color-assembly>
                            </div>
                        </div> -->
                        <div>
                            <div>答题页面标题栏颜色</div>
                            <div style="display: inline-block;">
                                <color-assembly color="gift.desc.titleColor3" isname="titleColor3" name="titleColor3"></color-assembly>
                            </div>
                        </div>
                        <div>
                            <div>结果页面成功标题栏色</div>
                            <div style="display: inline-block;">
                                <color-assembly color="gift.desc.titleColor1" isname="titleColor1" name="titleColor1"></color-assembly>
                            </div>
                        </div>
                        <div>
                            <div>结果页面失败标题栏色</div>
                            <div style="display: inline-block;">
                                <color-assembly color="gift.desc.titleColor2" isname="titleColor2" name="titleColor2"></color-assembly>
                            </div>
                        </div>
                        <div ng-if="gift.desc">
                            <div>结果页面猜图失败背景</div>

                            <img ng-src="{{gift.desc.err_background_img }}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.err_background_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <div ng-if="gift.desc">
                            <div>结果页面猜图成功背景</div>

                            <img ng-src="{{gift.desc.ok_background_img}}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.ok_background_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <div ng-if="gift.desc">
                            <div>结果页面猜图成功标题文字图</div>

                            <img ng-src="{{gift.desc.ok_title_img}}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.ok_title_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <div ng-if="gift.desc">
                            <div>结果页面猜图失败标题文字图</div>

                            <img ng-src="{{gift.desc.err_title_img}}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.err_title_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <div ng-if="gift.desc">
                            <div>猜图游戏规则图</div>

                            <img ng-src="{{gift.desc.modal_img}}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.modal_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <div ng-if="gift.desc">
                            <div>游戏成功输入手机号码背景图</div>

                            <img ng-src="{{gift.desc.modal_result_img}}" style="width: 120px;margin-bottom: 5px;" />
                            <br />
                            <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.modal_result_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                        </div>
                        <div ng-if="gift.desc">
                            <label>
                                <br /> 保存海报按钮图
                                <div class="shangxia">
                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item" dhf-ng-model="gift.desc.SAVEIMGbtn"
                                        xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                    <input ng-model="gift.desc.SAVEIMGbtn" type="text" name="name" value="" style="width:100px">
                                </div>
                                <div>
                                    <img ng-src="{{gift.desc.SAVEIMGbtn}}" style="width:150px;height: 50px;">
                                </div>
                            </label>
                            <label>
                                <br /> 转发按钮图
                                <div class="shangxia">
                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item" dhf-ng-model="gift.desc.ZFbtn"
                                        xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                    <input ng-model="gift.desc.ZFbtn" type="text" name="name" value="" style="width:100px">
                                </div>
                                <div>
                                    <img ng-src="{{gift.desc.ZFbtn}}" style="width:150px;height: 50px;">
                                </div>
                            </label>
                            <label>
                                <br /> 答题按钮图
                                <div class="shangxia">
                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item" dhf-ng-model="gift.desc.DTbtn"
                                        xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                    <input ng-model="gift.desc.DTbtn" type="text" name="name" value="" style="width:100px">
                                </div>
                                <div>
                                    <img ng-src="{{gift.desc.DTbtn}}" style="width:150px;height: 50px;">
                                </div>
                            </label>
                        </div>
                        <div ng-repeat="(id,v) in gift.desc.question" style="border-bottom:2px solid #eee;margin-bottom:5px;padding-bottom:10px">
                            <div>第{{$index+1}}题
                                <button style="margin-top: 10px;" type="button" class="sui-btn  btn-danger" ng-click="spliceArray('question',$index)">-删除本题</button>
                            </div>
                            <div>
                                <div>问题</div>
                                <input name="title" ng-model="v.title" placeholder="填写问题或提示" />
                            </div>
                            <div>
                                <div>问题描述图片（就是把问题的文字换成图片，图片优先及高）</div>
                                <img ng-src="{{v.title_img}}" style="width: 120px;margin-bottom: 5px;" />
                                <br />
                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="v.title_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                            </div>
                            <div>
                                <div>几张图片一行</div>
                                <input name="num" type="number" ng-model="v.imgnumrows" placeholder="几张图片一行" value="2" />
                            </div>
                            <div>
                                <div>答题时间（秒）</div>
                                <input name="endTime" type="number" ng-model="v.endTime" placeholder="答题时间（秒）" value="30" />
                            </div>
                            <div>
                                <div>装饰图(希腊文)</div>
                                <div class="shangxia">

                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="v.zhuangshi_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                    <input ng-model="v.zhuangshi_img" type="text" name="name" value="" style="width:100px">
                                </div>
                                <img ng-src="{{v.zhuangshi_img}}" style="width: 120px;margin-bottom: 5px;" />

                                <br />
                            </div>
                            <div style="border-bottom:2px solid #ccc;margin-bottom:5px;">
                                <div>答案</div>
                                <div class="shangxia">

                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="v.success_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                    <input ng-model="v.success_img" type="text" name="name" value="" style="width:100px">
                                </div>
                                <img ng-src="{{v.success_img}}" style="width: 120px;margin-bottom: 5px;" />

                                <br />
                            </div>
                            <div ng-repeat="error_img in v.error_imgs track by $index">

                                <div>第{{$parent.$index+1}}题，错误图片</div>
                                <div class="shangxia">
                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="v.error_imgs[$index]" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>

                                    <input ng-model="v.error_imgs[$index]" type="text" name="name" value="" style="width:100px">
                                    <button type="button" class="sui-btn btn-danger" ng-click="spliceChildArray('question',$parent.$index,'error_imgs',$index)" style="margin-left: 5px;">删除图片</button>
                                </div>
                                <br />
                                <img ng-src="{{v.error_imgs[$index]}}" style="width: 120px;margin-bottom: 5px;" />

                            </div>
                            <div>
                                <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="childArray('question',$index,'error_imgs')">+增加1个干扰项</button>
                            </div>
                        </div>
                        <div style="border-bottom: 2px solid #ccc;padding-bottom: 5px;">
                            <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="addArray('question',1)">+增加1题</button>
                        </div>
                        <div ng-if="gift.desc&&gift.desc.question.length">
                            <div>成功多少关显示闯关成功海报</div>
                            <div style="border-bottom: 2px solid #ccc;padding-bottom: 5px;">
                                <input name="ok_num" type="number" ng-model="gift.desc.ok_num" placeholder="大于或等于多少题算成功" value="1" />
                            </div>
                            <div>设置游戏成功和失败展示海报</div>
                            <div>
                                <div>失败海报</div>
                                <div ng-repeat="err_img in gift.desc.result_err_imgs ">
                                    <div class="shangxia">
                                        <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.result_err_imgs[$index]" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                        <input ng-model="gift.desc.result_err_imgs[$index]" type="text" name="name" value="" style="width:100px">
                                    </div>
                                    <img ng-src="{{gift.desc.result_err_imgs[$index]}}" style="width: 120px;margin-bottom: 5px;" />

                                    <div>
                                        <button style="margin-top: 10px;" type="button" class="sui-btn  btn-danger" ng-click="spliceArray('result_err_imgs',$index)">-删除本海报</button>
                                    </div>
                                </div>
                                <div>
                                    <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="addArray('result_err_imgs')">+增加1个闯关失败的海报</button>
                                </div>
                            </div>
                            <div>
                                <div>正确海报</div>
                                <div ng-repeat="err_img in gift.desc.result_ok_imgs ">
                                    <div class="shangxia">
                                        <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.result_ok_imgs[$index]" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                        <input ng-model="gift.desc.result_ok_imgs[$index]" type="text" name="name" value="" style="width:100px">

                                    </div>
                                    <br />
                                    <img ng-src="{{gift.desc.result_ok_imgs[$index]}}" style="width: 120px;margin-bottom: 5px;" />

                                    <div>
                                        <button style="margin-top: 10px;" type="button" class="sui-btn  btn-danger" ng-click="spliceArray('result_ok_imgs',$index)">-删除本海报</button>
                                    </div>
                                </div>
                                <div>
                                    <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="addArray('result_ok_imgs')">+增加1个闯关成功的海报</button>
                                </div>
                            </div>
                        </div>

                    </div>
                </div>
            </div>

        </div>
        <div ng-if="gift.type==3">
            <div class="control-group">
                <label class="control-label v-top">配置参数</label>
                <div class="controls">
                    <div>
                        <button class="sui-btn btn-primary" type="button" ng-click="setDesc(3)">添加默认数据</button>
                    </div>
                    <div>
                        <div>页面背景色：</div>
                        <div style="display: inline-block;">
                            <color-assembly color="gift.desc.bgColor1" isname="bgColor1" name="bgColor1"></color-assembly>
                        </div>
                    </div>
                    <div>
                        <div>标题栏背景色</div>
                        <div style="display: inline-block;">
                            <color-assembly color="gift.desc.titleColor" isname="titleColor" name="titleColor"></color-assembly>
                        </div>
                    </div>

                    <div ng-if="gift.desc&&gift.desc.beimian_img">
                        <div>纸牌背面</div>

                        <img ng-src="{{gift.desc.beimian_img}}" style="width: 120px;margin-bottom: 5px;" />
                        <br />
                        <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="gift.desc.beimian_img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                    </div>
                    <div>
                        <div>纸牌正面</div>
                        <div ng-repeat="(id,v) in gift.desc.zhengmian_img" style="border-bottom: 2px solid #ccc;padding-bottom: 5px;">
                            <div>第{{$index+1}}张</div>
                            <div>
                                <img ng-src="{{v.img}}" style="width: 120px;margin-bottom: 5px;" />
                                <br />
                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="v.img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                <button type="button" class="sui-btn btn-danger" ng-click="spliceArray('zhengmian_img',$index)" style="margin-left: 5px;">删除图片</button>
                            </div>
                        </div>
                        <div>
                            <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="addArray('zhengmian_img',1)">+增加1个</button>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div ng-if="gift.type==2||gift.type==5">
            <div class="control-group">
                <label class="control-label v-top">配置参数: </label>
                <div class="controls">
                    <div>
                        <button class="sui-btn btn-primary" type="button" ng-click="setDesc(gift.type)">添加默认数据</button>
                    </div>
                    <div>
                        <div style="border-bottom: 2px solid #ccc;">答案海报图：</div>
                        <div ng-repeat="(id,v) in gift.desc.answerItems" style="border-bottom: 2px solid #ccc;padding-bottom: 5px;">
                            <div>答案{{id}}：{{v.name}}</div>
                            <div>背景色：
                                <div style="display: inline-block;">
                                    <color-assembly color="v.titleColor" isname="{{v.name}}" name="{{v.name}}"></color-assembly>
                                </div>
                            </div>
                            <div>
                                <img ng-src="{{v.img}}" style="width: 120px;margin-bottom: 5px;" />
                                <br />
                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="gift" dhf-ng-model="v.img" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="control-group">
                <label class="control-label v-top">水印位置: </label>
                <div class="controls">
                    <div>
                        <input type="text" ng-model="gift.desc.textConfig.markPos[0]">=X
                    </div>
                    <div>
                        <input type="text" ng-model="gift.desc.textConfig.markPos[1]">=Y
                    </div>
                </div>
            </div>
            <div class="control-group">
                <label class="control-label v-top">水印文字大小: </label>
                <div class="controls">
                    <input type="text" ng-model="gift.desc.textConfig.fontSize">
                </div>
            </div>
            <div class="control-group">
                <label class="control-label v-top">水印文字宽度: </label>
                <div class="controls">
                    <input type="text" ng-model="gift.desc.textConfig.textWidth">
                </div>
            </div>
            <div class="control-group">
                <label class="control-label v-top">水印文字颜色: </label>
                <div class="controls">
                    <div style="display: inline-block;">
                        <color-assembly color="gift.desc.textConfig.textColor" isname="textColor" name="textColor"></color-assembly>
                    </div>
                </div>
            </div>
            <div ng-show="itemForm.desc.$error.required" class="sui-msg msg-error msg-clear help-block error">
                <div class="msg-con">{{'required'| translate}}</div>
                <div class="msg-icon"></div>
            </div>
        </div>
        <div class="control-group" ng-if="gift.type==1||gift.type==6">
            <label class="control-label v-top">配置参数:</label>
            <div class="controls">
                <ul id="tab-demo2" class="sui-nav nav-tabs nav-primary">
                    <li class="{{setPage=='dakaform'?'active':''}}">
                        <a href="#daka_home" data-toggle="tab" ng-click="tabCut($event);setCurrentPage('dakaform')">
                            打卡页面
                        </a>
                    </li>
                    <li class="{{setPage=='dakasuccess'?'active':''}}">
                        <a href="#daka_success" data-toggle="tab" ng-click="tabCut($event);setCurrentPage('dakasuccess')">
                            打卡成功页面
                        </a>
                    </li>
                </ul>
                <div class="tab-content">
                    <button class="sui-btn btn-primary" type="button" ng-click="setDesc(gift.type)">添加默认数据</button>
                    <div id="daka_home" class="tab-pane {{setPage=='dakaform'?'active':''}}">
                        <div style="width:375px;height:568px;float:left;margin-top:10px;">
                            <div style="{{setPage=='dakaform'?'border:2px solid red;':''}}width:100%;height:100%;background-image:url({{gift.desc.bg1}});background-size:100% 100%;position:relative;">
                                <div style="height:35px;display:flex;position:relative;width:320px;margin:0 auto;border:3px solid #1A1A1A;background:#fff;top:{{(375/750)*390}}px;">
                                    <input type="number" name="phone" style="padding-left: 10px;width:320px;height:29px;" />
                                    <img ng-if="gift.desc.phoneBg" ng-src="{{gift.desc.phoneBg}}" style="position:absolute;width:55px;right:-14px;bottom:0;"></img>
                                </div>
                                <label style="display: block;position:absolute;margin:0 auto;top:{{(375/750)*640}}px;width:100%;">
                                    <button class="zan-btn zan-btn--small" style="display:none;" form-type="submit">领取礼物
                                    </button>
                                    <image ng-src="{{gift.desc.LQLWbtn}}" style="width:150px;margin:0 auto;display:block;"></image>
                                </label>
                            </div>
                        </div>
                    </div>
                    <div id="daka_success" class="tab-pane {{setPage=='dakasuccess'?'active':''}}">
                        <div style="width:375px;height:568px;float:left;margin-top:10px;" ng-if="gift&&gift.type==1">
                            <div style="{{setPage=='dakasuccess'?'border:2px solid red;':''}}width:100%;height:100%;background-image:url({{gift.desc.bg2}});background-size:100% 100%;position:relative;">
                                <img ng-src="{{gift.desc.SAVEwallpaper[img_num]}}" style="position:relative;height:{{(375/750)*580}}px;margin:0 auto;display:block;top:{{(375/750)*180}}px;z-index:9;" />
                                <div style="display:flex;position:absolute;bottom:{{(375/750)*120}}px;width:100%;">
                                    <div style="flex: 1;" ng-if="gift.desc.SAVEIMGbtn">
                                        <label style="display: block;position:relative;margin:0 auto;margin-top:15px;">
                                            <button class="zan-btn zan-btn--small" style="display:none;" catchtap="saveImg">
                                                保存壁紙按钮图
                                            </button>
                                            <image ng-src="{{gift.desc.SAVEIMGbtn}}" mode="widthFix" style="width:100px;margin:0 auto;display:block;"></image>
                                        </label>
                                    </div>
                                    <div style="flex: 1;" ng-if="gift.desc.ZFbtn">
                                        <label style="display: block;position:relative;margin:0 auto;margin-top:15px;">
                                            <button class="zan-btn zan-btn--small" style="display:none;" catchtap="saveImg">
                                                转发按钮图
                                            </button>
                                            <image ng-src="{{gift.desc.ZFbtn}}" mode="widthFix" style="width:100px;margin:0 auto;display:block;"></image>
                                        </label>
                                    </div>
                                    <div style="flex: 1;" ng-if="gift.desc.DTbtn">
                                        <label style="display: block;position:relative;margin:0 auto;margin-top:15px;">
                                            <button class="zan-btn zan-btn--small" style="display:none;" catchtap="saveImg">
                                                跳转答题按钮图
                                            </button>
                                            <image ng-src="{{gift.desc.DTbtn}}" mode="widthFix" style="width:100px;margin:0 auto;display:block;"></image>
                                        </label>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div style="position:absolute;right:100px;width:400px;">
                    <div class="sui-row mar-top" style="overflow-y: scroll;height: 568px;margin-left:5px">
                        <ul class="card-list">
                            <li class="re-li">
                                <div class="sui-form">
                                    <div ng-if="setPage=='dakaform'">
                                        <label>
                                            <br /> 第1背景图:
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                    dhf-ng-model="gift.desc.bg1" xtype="url" mult="false" title="Upload"
                                                    use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.bg1" type="text" name="name" value="" style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.bg1}}" style="width:240px;height: 320px;">
                                            </div>
                                        </label>
                                        <label>
                                            <br /> 手机号码装饰图：
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                    dhf-ng-model="gift.desc.phoneBg" xtype="url" mult="false" title="Upload"
                                                    use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.phoneBg" type="text" name="name" value=""
                                                    style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.phoneBg}}" style="width:160px;height: 60px;">
                                            </div>
                                        </label>
                                        <label>
                                            <br /> 领取礼物按钮：
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                    dhf-ng-model="gift.desc.LQLWbtn" xtype="url" mult="false" title="Upload"
                                                    use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.LQLWbtn" type="text" name="name" value=""
                                                    style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.LQLWbtn}}" style="width:150px;height: 50px;">
                                            </div>
                                        </label>
                                    </div>
                                    <div ng-if="setPage=='dakasuccess'">
                                        <div>
                                            第2背景图：
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item" dhf-ng-model="gift.desc.bg2" xtype="url" mult="false" title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.bg2" type="text" name="name" value="" style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.bg2}}" style="width:240px;height: 320px;">
                                            </div>
                                        </div>
                                        <div>
                                            <br /> 页面预览展示的海报图：
                                            <label ng-repeat="wallobj in gift.desc.SAVEwallpaper track by $index" style="display: block">
                                                第{{$index+1}}张:
                                                <div class="shangxia">
                                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                        dhf-ng-model="gift.desc.SAVEwallpaper[$index]" xtype="url" mult="false"
                                                        title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                    <input ng-model="gift.desc.SAVEwallpaper[$index]" type="text" name="name"
                                                        value="" style="width:100px">
                                                    <button type="button" class="sui-btn btn-danger" ng-click="spliceArray('SAVEwallpaper',$index)"
                                                        style="margin-left: 5px;">删除图片</button>
                                                </div>
                                                <div>
                                                    <img ng-src="{{gift.desc.SAVEwallpaper[$index]}}" style="width:240px;height: 320px;">
                                                </div>
                                            </label>
                                            <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="addArray('SAVEwallpaper')">+增加1个</button>
                                        </div>
                                        <div style="margin-top: 10px;">
                                            <div style="color:red;">顾客执行下载保存的海报图（与上面的【页面预览展示的海报图】数量一定要一样）：</div>
                                            <label ng-repeat="saveimg in gift.desc.wallpaper track by $index" style="display: block">
                                                第{{$index+1}}张:
                                                <div class="shangxia">
                                                    <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                        dhf-ng-model="gift.desc.wallpaper[$index]" xtype="url" mult="false"
                                                        title="Upload" use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                    <input ng-model="gift.desc.wallpaper[$index]" type="text" name="name"
                                                        value="" style="width:100px">
                                                    <button type="button" class="sui-btn btn-danger" ng-click="spliceArray('wallpaper',$index)"
                                                        style="margin-left: 5px;">删除图片</button>
                                                </div>
                                                <div>
                                                    <img ng-src="{{gift.desc.wallpaper[$index]}}" style="width:240px;height: 320px;">
                                                </div>
                                            </label>
                                            <button style="margin-top: 10px;" type="button" class="sui-btn  btn-success" ng-click="addArray('wallpaper')">+增加1个</button>
                                        </div>
                                        <label>
                                            <br /> 保存海报按钮图
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                    dhf-ng-model="gift.desc.SAVEIMGbtn" xtype="url" mult="false" title="Upload"
                                                    use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.SAVEIMGbtn" type="text" name="name" value=""
                                                    style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.SAVEIMGbtn}}" style="width:150px;height: 50px;">
                                            </div>
                                        </label>
                                        <label>
                                            <br /> 转发按钮图
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                    dhf-ng-model="gift.desc.ZFbtn" xtype="url" mult="false" title="Upload"
                                                    use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.ZFbtn" type="text" name="name" value=""
                                                    style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.ZFbtn}}" style="width:150px;height: 50px;">
                                            </div>
                                        </label>
                                        <label>
                                            <br /> 答题按钮图
                                            <div class="shangxia">
                                                <attachment owner-id="gift.gift_id ?gift.gift_id:1" owner-type="item"
                                                    dhf-ng-model="gift.desc.DTbtn" xtype="url" mult="false" title="Upload"
                                                    use-type="png,jpeg,gif,jpg,JPG,PNG,JPEG,GIF"></attachment>
                                                <input ng-model="gift.desc.DTbtn" type="text" name="name" value=""
                                                    style="width:100px">
                                            </div>
                                            <div>
                                                <img ng-src="{{gift.desc.DTbtn}}" style="width:150px;height: 50px;">
                                            </div>
                                        </label>
                                    </div>
                                </div>
                            </li>
                        </ul>
                    </div>
                </div>
            </div>
        </div>
        <div class="control-group" style="margin-top:35px;">
            <label class="control-label"></label>
            <div class="controls">
                <button type="submit" id="submit" class="sui-btn btn-primary" ng-disabled="!itemForm.$valid ">
                    <span>{{'save' | translate}}</span>
                </button>
            </div>
        </div>
    </form>
</div>